<?php
/* @var $this SpectacleRxNearController */
/* @var $model SpectacleRxNear */
/* @var $form CActiveForm */
?>

<div class="form">

<?php $form=$this->beginWidget('CActiveForm', array(
	'id'=>'spectacle-rx-near-form',
	'enableAjaxValidation'=>false,
)); ?>

	<p class="note">Fields with <span class="required">*</span> are required.</p>

	<?php echo $form->errorSummary($model); ?>

	<div class="column">
		<?php echo $form->labelEx($model,'od_pd'); ?>
		<?php echo $form->textField($model,'od_pd',array('size'=>5,'maxlength'=>5)); ?>
		<?php echo $form->error($model,'od_pd'); ?>
	</div>

	<div class="row">
		<?php echo $form->labelEx($model,'od_sph'); ?>
		<?php echo $form->textField($model,'od_sph',array('size'=>5,'maxlength'=>5)); ?>
		<?php echo $form->error($model,'od_sph'); ?>
	</div>

	<div class="column">
		<?php echo $form->labelEx($model,'od_cyl'); ?>
		<?php echo $form->textField($model,'od_cyl',array('size'=>5,'maxlength'=>5)); ?>
		<?php echo $form->error($model,'od_cyl'); ?>
	</div>

	<div class="row">
		<?php echo $form->labelEx($model,'od_axis'); ?>
		<?php echo $form->textField($model,'od_axis',array('size'=>5,'maxlength'=>5)); ?>
		<?php echo $form->error($model,'od_axis'); ?>
	</div>

	<div class="column">
		<?php echo $form->labelEx($model,'od_prism'); ?>
		<?php echo $form->textField($model,'od_prism',array('size'=>5,'maxlength'=>5)); ?>
		<?php echo $form->error($model,'od_prism'); ?>
	</div>

	<div class="row">
		<?php echo $form->labelEx($model,'od_add'); ?>
		<?php echo $form->textField($model,'od_add',array('size'=>5,'maxlength'=>5)); ?>
		<?php echo $form->error($model,'od_add'); ?>
	</div>

	<div class="column">
		<?php echo $form->labelEx($model,'os_pd'); ?>
		<?php echo $form->textField($model,'os_pd',array('size'=>5,'maxlength'=>5)); ?>
		<?php echo $form->error($model,'os_pd'); ?>
	</div>

	<div class="row">
		<?php echo $form->labelEx($model,'os_sph'); ?>
		<?php echo $form->textField($model,'os_sph',array('size'=>5,'maxlength'=>5)); ?>
		<?php echo $form->error($model,'os_sph'); ?>
	</div>

	<div class="column">
		<?php echo $form->labelEx($model,'os_cyl'); ?>
		<?php echo $form->textField($model,'os_cyl',array('size'=>5,'maxlength'=>5)); ?>
		<?php echo $form->error($model,'os_cyl'); ?>
	</div>

	<div class="row">
		<?php echo $form->labelEx($model,'os_axis'); ?>
		<?php echo $form->textField($model,'os_axis',array('size'=>5,'maxlength'=>5)); ?>
		<?php echo $form->error($model,'os_axis'); ?>
	</div>

	<div class="column">
		<?php echo $form->labelEx($model,'os_prism'); ?>
		<?php echo $form->textField($model,'os_prism',array('size'=>5,'maxlength'=>5)); ?>
		<?php echo $form->error($model,'os_prism'); ?>
	</div>

	<div class="row">
		<?php echo $form->labelEx($model,'os_add'); ?>
		<?php echo $form->textField($model,'os_add',array('size'=>5,'maxlength'=>5)); ?>
		<?php echo $form->error($model,'os_add'); ?>
	</div>

	<div class="column">
		<?php echo $form->labelEx($model,'rx_id'); ?>
		<?php echo $form->dropDownList($model,'rx_id', CHtml::listData(
                Rx::model() ->findAll(), 'id','id'), array('prompt' => 'Select Rx')); 
                ?>
		<?php echo $form->error($model,'rx_id'); ?>
	</div>

	<div class="row">
		<?php echo $form->labelEx($model,'personalinfo_id'); ?>
		<?php echo $form->dropDownList($model,'personalinfo_id', CHtml::listData(

		PersonalInformation::model() ->findAll(), 'id','fname', 'lname'), array('prompt' => 'Select Person')); ?>

		<?php echo $form->error($model,'personalinfo_id'); ?>
	</div>

	<div class="row buttons">
		<?php echo CHtml::submitButton($model->isNewRecord ? 'Create' : 'Save'); ?>
	</div>

<?php $this->endWidget(); ?>

</div><!-- form -->